#ifndef _CAMERADRV_H_
#define _CAMERADRV_H_
/*供应商选择*/
enum cameraSupplier
{
    Hikvision,
    Others,
};


/* 传输模式 */
enum transmode
{
    Unvarnished,//透传
    Custom,
};

/* 摄像头操作 */
typedef struct cameraopt
{
    int (*write)(void*setPar);
    int (*read)(void*getPar);
    int (*init)();
}cameraOpt,*pCameraOpt;

/* 摄像头对象 */
typedef struct camera
{
    struct camera * next;
    enum cameraSupplier manufacturers; //摄像头厂家
    char* name;                        //摄像头名称
    pCameraOpt cameraObjOpt;           //摄像头操作函数集
    enum transmode transMode;          //数据传输模式
}cameraObj,*pCameraObj;


/* 函数声明 */
pCameraObj cameraFind(char* name);
unsigned int cameraWrite(pCameraObj obj,void *date);
unsigned int cameraRead(pCameraObj obj,void* data);
unsigned int cameraInit(pCameraObj obj);
unsigned int cameraRegister(pCameraObj obj);











#endif